package com.cg.service.impl;

import java.util.List;
import java.util.Map;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.cg.dao.AppHomePicDao;
import com.cg.entity.AppHomePic;
import com.cg.utils.R;

/**
 * app首页轮播图配置
 * @author cumt
 *
 */
@Service("appHomePicServiceImpl")
public class AppHomePicServiceImpl {
	@Autowired
	AppHomePicDao appHomePicDao;
	
	public List<AppHomePic> queryList(Map<String, Object> params){
		
		return appHomePicDao.queryList(params);
	}
	
	public R save(AppHomePic hompic){
		appHomePicDao.save(hompic);
		return R.ok();
	}
	
	public int queryTotal(Map<String,Object> query) {
		
		return appHomePicDao.queryTotal();
	}
	
	public R update(AppHomePic hompic){
		appHomePicDao.update(hompic);
		return R.ok();
	}
	
	public void deleteBatch(Long[] ids) {
		appHomePicDao.deleteBatch(ids);
	}

	
	public AppHomePic queryObject(Long id) {
		return appHomePicDao.queryObject(id);
	}

}
